import TabsView from '@/layouts/tabs/TabsView'
import BlankView from '@/layouts/BlankView'
//import PageView from '@/layouts/PageView'

// 路由配置
const options = {
  routes: [
    {
      path: '/login',
      name: '登录页',
      component: () => import('@/pages/login')
    },
    {
      path: '*',
      name: '404',
      component: () => import('@/pages/exception/404'),
    },
    {
      path: '/403',
      name: '403',
      component: () => import('@/pages/exception/403'),
    },
    {
      path: '/',
      name: '首页',
      component: TabsView,
      redirect: '/login',
      children: [
        {
          path: 'dashboard',
          name: '工作台',
          meta: {
            icon: 'dashboard'
          },
          component: () => import('@/pages/system/Dashboard')
        },
        {
          path: 'system',
          name: '系统管理',
          meta: {
            icon: 'setting',
          },
          component: BlankView,
          children: [
           
            {
              path: 'roles',
              name: '角色管理',
              component: () => import('@/pages/system/Roles'),
            },
            {
              path: 'users',
              name: '用户管理',
              component: () => import('@/pages/demo/Demo'),
            },
            {
              path: 'menus',
              name: '菜单管理',
              component: () => import('@/pages/demo/Demo'),
            },
            {
              path: 'organization',
              name: '组织架构',
              component: () => import('@/pages/demo/Demo'),
            },
            {
              path: 'logs',
              name: '系统日志',
              component: () => import('@/pages/demo/Demo'),
            },
            {
              path: 'datadict',
              name: '通用字典',
              component: () => import('@/pages/system/DataDict'),
            },
            {
              path: 'config',
              name: '选项设置',
              component: () => import('@/pages/demo/Demo'),
            },
          ]
        },
        
        {
          name: '验权页面',
          path: 'auth/demo',
          meta: {
            icon: 'file-ppt',
            authority: {
              permission: 'form',
              role: 'manager'
            },
            component: () => import('@/pages/demo')
          }
        }
      ]
    }
  ]
}

export default options
